package com.bonc.rms.dao.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import com.bonc.rms.dao.PetInfoDao;
import com.bonc.rms.mapper.PetInfoMapper;

@Repository(value = "petInfoDaoImpl")
public class PetInfoDaoImpl implements PetInfoDao{
	@Autowired
	PetInfoMapper petInfoMapper;

	@Override
	public List<Map<String, Object>> getPetInfo() {
		return petInfoMapper.getPetInfo();
	}

	@Override
	public List<Map<String, Object>> updatePetInfo(Integer petId, String petNumber, String petName, String pic,
			String sex, String age, String size, String variety, String character, String price) {
		return petInfoMapper.updatePetInfo(petId, petNumber, petName, pic,
				 sex,  age,  size,  variety,  character,  price);
	}

	@Override
	public Object deletePetInfo(Integer petId) {
		return petInfoMapper.deletePetInfo(petId);
	}

	@Override
	public List<Map<String, Object>> addPetInfo(Integer petId, String petName, String pic, String sex,
			String age, String size, String variety, String character, String price) {
		return petInfoMapper.addPetInfo(petId, petName, pic,
				 sex,  age,  size,  variety,  character,  price);
	}

	@Override
	public List<Map<String, Object>> getSinglePetInfo(Integer petId) {
		return petInfoMapper.getSinglePetInfo(petId);
	}

}
